<%@ page import="main.java.com.entity.Employee" %><%--
  Created by IntelliJ IDEA.
  User: 廖国才
  Date: 2024/12/18
  Time: 16:43
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>Title</title>
</head>
<body>


  <form action="${pageContext.request.contextPath}/updateemployee">
    <p><input type="hidden" name="id" value="${employee.id}"></p>
    <p>账号：<input type="text" name="username" value="${employee.username}"></p>
    <p>员工姓名：<input type="text" name="name"
                       value="${employee.name}"></p>
    <p>手机号：<input type="text" name="phone"
                     value="${employee.phone}"></p>
    <c:if test="${employee.sex ==1}">
    <p>性别：<input type="radio" name="sex" value="男" checked>男
      <input type="radio" name="sex" value="女"> 女</p>
    </c:if>
<c:if test="${employee.sex ==2}">
    <p>性别：<input type="radio" name="sex" value="男">男
      <input type="radio" name="sex" value="女" checked> 女</p>
</c:if>

    <p>身份证号：<input type="text" name="idNumber" value="${employee.idNumber}"></p>
    <p><button id="closebtn">取消</button>
      <input type="submit" value="保存">
      </p>
  </form>
<script>
  let closebtn = document.getElementById("closebtn")
  closebtn.onclick=function (){
    close();
  }
</script>
</body>
</html>
